package com.example.design.openfeign;

import org.springframework.cloud.openfeign.SpringQueryMap;
import org.springframework.web.bind.annotation.*;

import java.util.Map;

/**
 * 定义Feign通用接口
 * @author wangli
 * @version 1.0
 * @date 2023/9/19 12:28
 */
public interface DynamicService {
    @PostMapping(value = "{url}")
    Object executePostApi(@PathVariable("url") String url, @RequestBody Object params, @RequestHeader Map<String, String> headers, @SpringQueryMap Object requestPage);

    @GetMapping(value = "{url}")
    Object executeGetApi(@PathVariable("url") String url, @SpringQueryMap Object params, @RequestHeader Map<String, String> headers);
}
